with open(r"D:\桌面\数据模型\day31\代码\PET\checkpoints\model_best_old\vocab.txt",'r',encoding='utf-8') as f:
    vocab_size = len(f.readlines())
print(vocab_size)

from transformers import AutoConfig
config = AutoConfig.from_pretrained('bert-base-chinese')
print(config.vocab_size)